package com.ifreeee.practice.aop;


import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

@Component
@Aspect
public class MyAspectJ {

    @Pointcut("execution(* com.ifreeee.practice.aop.proxy.*.*(..))")
    public void pointCut () {

    }

    @Before("pointCut()")
    public void before () {
        System.out.println("前 执行....");
    }

    @After("pointCut()")
    public void after () {
        System.out.println("后 执行....");
    }
}
